home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / borland / svgabg52.zip / SVGA64K.H < prev    next >
Text File  |  1993-04-20  |  1KB  |  49 lines

  1. /************************************************/
  2. /*                         */
  3. /*      SuperVGA 65536 BGI driver defines    */
  4. /*        Copyright (c) 1993        */
  5. /*        Jordan Hargraphix Software        */
  6. /*                        */
  7. /************************************************/
  8.  
  9. extern int far _Cdecl Svga64k_fdriver[];
  10.  
  11. /* These are the currently supported modes */
  12. #ifndef SVGA320x200x65536
  13. #define    SVGA320x200x65536    0    /* 320x200x65536 HiColor VGA */
  14. #define    SVGA640x350x65536    1    /* 640x350x65536 HiColor VGA */
  15. #define    SVGA640x400x65536    2    /* 640x400x65536 HiColor VGA */
  16. #define    SVGA640x480x65536    3    /* 640x480x65536 HiColor VGA */
  17. #define    SVGA800x600x65536    4    /* 800x600x65536 HiColor VGA */
  18. #endif
  19.  
  20. #ifndef XNOR_PUT
  21. #define    XNOR_PUT    5
  22. #define NOR_PUT        6
  23. #define NAND_PUT    7
  24. #define TRANS_COPY_PUT    8    /* Doesn't work with 16-color drivers */
  25. #endif
  26.  
  27. #define RGB(r,g,b) ((r & 31)<<11) | ((g & 31)<<5) | (b & 31)
  28.  
  29. int RealDrawColor(int color)
  30. {
  31.   if (getmaxcolor() > 256) 
  32.     setrgbpalette(1024,(color>>11)&31,(color>>5)&63,color&31);
  33.   return(color);
  34. }
  35.  
  36. int RealFillColor(int color)
  37. {
  38.   if (getmaxcolor() > 256)
  39.     setrgbpalette(1025,(color>>11)&31,(color>>5)&63,color&31);
  40.   return(color);
  41. }
  42.  
  43. int RealColor(int color)
  44. {
  45.   if (getmaxcolor() > 256)
  46.     setrgbpalette(1026,(color>>11)&31,(color>>5)&63,color&31);
  47.   return(color);
  48. }
  49.